<!DOCTYPE html>
<html lang="zh">
	<head>
		<meta charset="UTF-8">
		<title>screen对象</title>
	</head>
	<body>
		<input type="button" value="显示屏幕的宽度和高度" onclick="click1()" />
		<input type="button" value="显示屏幕的可用宽度和高度" onclick="click2()" />
		<script type="text/javascript">
			function click1(){
				var w=window.screen.width;
				var h=window.screen.height;
				alert(w+"-----"+h);
			}
			function click2(){
				var w=window.screen.availWidth;
				var h=window.screen.availHeight;
				alert("可用"+w+"-----"+h);
			}
			
		</script>
	</body>
</html>
